Getting Started#
TL;DR#
pip install waloviz
apt-get install ffmpeg
import waloviz as wv
wv.extension()
wv.Audio('https://www2.cs.uic.edu/~i101/SoundFiles/CantinaBand3.wav')
Explanation#
waloviz was built to be as accessible as possible, whether you’re using colab, jupyter, JupyterLab, VSCode or just pure HTML - you’ll only need three lines of code.
First we need to install waloviz:
pip install waloviz
We also need to install ffmpeg as a backend for torchaudio:
apt-get install ffmpeg
Then we need to import waloviz and activate the extension:
import wavloviz as wv
wv.extension()
Then we need to call wv.Audio with our URL or file-path:
wv.Audio('https://www2.cs.uic.edu/~i101/SoundFiles/CantinaBand3.wav')
And… that’s it, you’re done.
You can use the player to interact with your audio.
Using the player#
The controls are pretty intuitive, but here are the most important controls you should to know:
A single click anywhere - toggles play\pause.
Scrolling with the mouse wheel - zooms in\out.
Dragging the mouse while pressing down - moves forwards\backwards.
The small ↺ icon on the top left - resets to the initial view.
Clicking on the
Download waloviz.html- will download an HTML version of the player.
To learn more, read our User Guide.